#!/bin/bash

# apt update && apt install -y git && cd ~ && git clone https://atomgit.com/ntlv1/server-tools.git && bash server-tools/vm/setup.sh

read -p "tsinghua source"
cat ~/server-tools/vm/debian_sources/tsinghua.txt > /etc/apt/sources.list

read -p "common setup"
bash ~/server-tools/common/setup/setup.sh

read -p "docker install"
bash ~/server-tools/common/docker/docker_install_public.sh

clear

# static ip
# head -n -2 /etc/network/interfaces > interfaces_temp
# vi interfaces_temp
###############################
# auto ens33
#     address 192.168.128.10
#     netmask 255.255.255.0
#     gateway 192.168.128.2
#     dns-nameservers 223.5.5.5
###############################
# mv interfaces_temp /etc/network/interfaces

# apt update && apt install openssh-server && echo "PermitRootLogin yes" >> /etc/ssh/sshd_config